package com.example.demo.simple;

import io.swagger.annotations.ApiOperation;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.web.bind.annotation.*;


@RestController
@RequestMapping("simple")
public class HelloController {
    @Autowired
    private HelloSender helloSender;

    @ApiOperation("最简单的单生产者和单消费者")
    @GetMapping("send/{message}")
    @ResponseBody
    public String send(@PathVariable("message") String message) {
        helloSender.send(message);
        return message;
    }
}
